function [pxx,f]=FFT_of_signal(t,y,plotting)
    if (~exist('plotting', 'var'))
        plotting = true;
    end
[pxx,f]=plomb(y,t);
%plot(f,pxx)
if plotting
    figure()
    loglog(f,smooth(pxx),'linewidth',2)
%     loglog(f,pxx,'linewidth',1.5)
    xlabel('Frequency-Hz')
    ylabel('Torque Intensity-mNm')
    title('Spectrum of Torque Fluctuation')
    set(gca,'linewidth',2)
    set(gca,'fontsize',16)
end